<!DOCTYPE html>
<html lang="zh-CN">
  <head>
  	<meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=Edge">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    
    <title>e8通用后台</title>
    
    <!-- 新 Bootstrap 核心 CSS 文件 -->
    <link rel="stylesheet" href="__PUBLIC__/admin/default/lib/bootstrap/bootstrap.min.css">
	<link rel="stylesheet" href="__PUBLIC__/admin/default/lib/font-awesome/css/font-awesome.min.css">
    
    <!--[if lt IE 9]>
      <script src="http://cdn.bootcss.com/html5shiv/3.7.2/html5shiv.min.js"></script>
      <script src="http://cdn.bootcss.com/respond.js/1.4.2/respond.min.js"></script>
    <![endif]-->
    
    <!-- e8 style -->
    <link rel="stylesheet" href="__PUBLIC__/admin/default/css/common.css">
    <link rel="stylesheet" href="__PUBLIC__/admin/default/css/main.css">
    
  </head>
  
  <body>
  
  	<div class="topbar">
    	<!-- 面包屑 -->
        <include file="./Apps/Admin/View/Include/mbx.html" />
        
        <div class="topbar-search">
        	<form class="form-inline" role="form">
            	<div class="form-group">
            		<label class="sr-only" for="exampleInputEmail2">Email address</label>
            		<input type="email" class="form-control input-sm" id="exampleInputEmail2" placeholder="Enter email">
                    
                    <i class="fa fa-search color-gray"></i>
          		</div>
            </form>
        </div>
    </div><!-- /.topbar -->
    
    <div class="page-content">
    
        <div class="page-header col-sm-12">
        	<h1>栏目修改</h1>
        </div>
        
        
        <div class="col-sm-12">
			<div class="tabbable">
				<ul class="nav nav-tabs">
					<li>
						<a href="__APP__/Class/index">栏目管理</a>
					</li>

					<li>
						<a href="__APP__/Class/add">添加栏目</a>
					</li>
                    
                    <li>
						<a href="__APP__/Class/addlink">添加外部链接栏目</a>
					</li>
				</ul>
				
				<div class="tab-content">
                    <div class="tab-pane in active">
                    	 <p class="title background-blue">基本属性</p>
                         <form action="__APP__/Class/editlink" method="post" enctype="multipart/form-data">
                         	<input type="hidden" name="id" value="{$class.id}"/>
                            <table width="100%" class="table-form">
                                <tbody>
                                     <tr>
                                            <th width="160">上级栏目</th>
                                            <td>
                                                 <span class="col-sm-4">
                                                    <select class="form-control input-sm" name="parentid">
                                                 		<option value="0">==作为一级菜单==</option>
	                                                 	<foreach name="classarr" item="classList">
	                                                 		<option value="{$classList.id}" {$classList.select}>{$classList.prefix}{$classList.classname}</option>
	                                                 	</foreach>
                                                </select>
                                                 </span>
                                            </td>
                                       </tr>
                                       <tr>
                                            <th width="160">栏目名称</th>
                                            <td>
                                                  <span class="col-sm-4"><input type="text" class="form-control input-sm" placeholder="请输入栏目名称" name="classname" value="{$class.classname}"/></span>
                                            </td>
                                       </tr>
                                       <tr>
                                            <th>栏目缩略图</th>
                                            <td>
                                                 <span class="col-sm-4"> <img class="img-circle" id="photo" src="{$Think.config.UPLOAD_PATH}{$class.image}" alt="{$class.image}" style="width:70px;heihgt:70px;"></span>
                                            </td>
                                       </tr>
                                       <tr>
                                            <th>上传缩略图</th>
                                            <td>
                                                 <span class="col-sm-4"><input type="file" name="image"/></span>
                                            </td>
                                       </tr>
                                       <tr>
                                            <th>栏目简介</th>
                                            <td>
                                                <span class="col-sm-4"><textarea class="form-control" style="height:90px;" name="introduce">{$class.introduce}</textarea></span>
                                            </td>
                                    	</tr>
                                         <tr>
                                            <th>链接地址</th>
                                            <td>
                                                 <span class="col-sm-4"><input type="text" name="url" class="form-control input-sm" placeholder="请输入链接地址" value="{$class.url}"/></span>
                                            </td>
                                       </tr>
                                </tbody>
                            </table>
                             <div style="width:100%;height:60px;"></div>
                             <div class="admin-add">
                            	<button class="btn btn-primary btn-sm" type="submit">提交</button>
                             </div>
                         </form>
                    </div>
                    
				</div>
			</div>
		</div><!-- /span -->
        
    </div><!-- /.page-content -->
    <!-- 图片弹出层 -->
    <div id="outerdiv"
        style="position: fixed; top: 0; left: 0; background: rgba(0, 0, 0, 0.7); z-index: 10000; width: 100%; height: 100%; display: none;">
        <div id="innerdiv" style="position: absolute;">
          <img id="bigimg" style="border: 5px solid #fff;" src="" />
        </div>
    </div>
  
  
    <!-- jQuery文件 -->
	<script src="http://cdn.bootcss.com/jquery/1.11.1/jquery.min.js"></script>
    <!-- 最新的 Bootstrap 核心 JavaScript 文件 -->
	<script src="__PUBLIC__/admin/default/lib/bootstrap/bootstrap.min.js"></script>
    <!--  -->
	<script src="__PUBLIC__/admin/default/js/e8.js"></script>
	<script src="__PUBLIC__/admin/default/js/fun.js"></script>
	<script>
    $(document).ready(function() { 
        $("#photo").click(function(){
            var _this = $(this);//将当前的元素作为_this传入函数
            imgShow("#outerdiv", "#innerdiv", "#bigimg", _this);
        });
    });
    </script>
  </body>
</html>
